1. Field of the Invention
The present invention relates to an apparatus for executing macros realizing a stored operation sequence to be carried out via an operation unit and to a control method for the apparatus.
2. Related Background Art
Some recent multi function peripheral (MFP) is provided with a macro function of sequentially storing an operation sequence such as predetermined key depression by a user and reproducing the stored operation sequence (for example, refer to Japanese Patent Application Laid-open Publication No. 2000-222100).
Processes to be executed on the basis of a user operation include processes to be executed upon an event occurrence synchronous with the user operation and processes to be executed upon an event occurrence asynchronous with the user operation. Processes to be executed upon an event occurrence asynchronous with a user operation are, for example, a lightweight directory access protocol (LDAP) reception process in which an external server connected to MFP searches a predetermined address by using LDAP which is a client-server protocol for accessing directory services to transmit data and MFP receives a response (address) from the external server. Namely, if an operation sequence for a send process is to be recorded as macros, these macros execute the send process by acquiring a desired address by using the LDAP reception process and thereafter transmitting data to the address. In the LDAP reception process, the user operation becomes asynchronous because of the time taken to acquire the response from the external server.
Although MFP can process an event synchronous with a user operation without any problem in executing a reproduce process of the macro function, it cannot process an event occurrence asynchronous with a user operation, such as the LDAP reception process. This is because there is a delay time due to a network congestion state, an external server state and the like, before MFP actually receives an address after an instruction of starting the LDAP reception process.
In order to operate the macro function without any problem, there is a wait time recording method which is a program for making a recorded event maintain a standby state for a predetermined time. For example, it can be considered to use a method by which a user estimates an event process time and records a predetermined wait time.
However, with this method of recording a predetermined wait time, even if an event is processed before the predetermined wait time, for the macro reproduction, the standby state continues for the recorded wait time wastefully. On the other hand, if a shorter wait time is recorded, there is a possibility that the next operation sequence is performed before the necessary information is acquired so that a proper reproduction is impossible.
It is therefore desired to configure MFP to improve a user operation performance and to customize the wait time recording method more in detail for users. It is also desired to reliably operate the macro function even if an operation sequence has an event occurrence asynchronous with a user operation.